package com.lanou.utils;

import javax.servlet.http.Cookie;

/**
 * Created by lanouhn on 2017/9/12.
 */
public class CookieUtils {
    public static Cookie getCookie(Cookie[] cookies, String name){
        if (cookies!=null){
            for (Cookie cookie :cookies){
                if (name.equals(cookie.getName())){
                    return cookie;
                }
            }

        }
        return null;
    }
}
